package com.zrrd.io.propertiesDemo;

import java.util.Properties;
import java.util.Set;

/**
 * @author WanJl
 * @version 1.0
 * @title PropertiesDemo01
 * @description
 * @create 2023/10/15 11:15
 */
public class PropertiesDemo01 {
    public static void main(String[] args) {
        Properties prop = new Properties();
        prop.put("name","张三");
        prop.put("age",25);
        prop.put("sex","男");


        //遍历集合
        Set<Object> keySet = prop.keySet();
        for (Object key:keySet){
            Object value = prop.get(key);
            System.out.println(key+"="+value);
        }
    }
}
